{
  "nbformat": 4,
  "nbformat_minor": 0,
  "metadata": {
    "colab": {
      "provenance": []
    },
    "kernelspec": {
      "name": "python3",
      "display_name": "Python 3"
    },
    "language_info": {
      "name": "python"
    },
    "accelerator": "TPU"
  },
  "cells": [
    {
      "cell_type": "code",
      "source": [
        "!git clone https://github.com/LC1332/Chat-Haruhi-Suzumiya"
      ],
      "metadata": {
        "id": "-3f02GWMf2Xu",
        "outputId": "0a776dd3-ae36-4903-baf8-5b25d5388821",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 1,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Cloning into 'Chat-Haruhi-Suzumiya'...\n",
            "remote: Enumerating objects: 17499, done.\u001b[K\n",
            "remote: Counting objects: 100% (1982/1982), done.\u001b[K\n",
            "remote: Compressing objects: 100% (1741/1741), done.\u001b[K\n",
            "remote: Total 17499 (delta 335), reused 1808 (delta 230), pack-reused 15517\u001b[K\n",
            "Receiving objects: 100% (17499/17499), 451.01 MiB | 20.94 MiB/s, done.\n",
            "Resolving deltas: 100% (2713/2713), done.\n",
            "Updating files: 100% (12120/12120), done.\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "!ls /content/Chat-Haruhi-Suzumiya/characters/haruhi"
      ],
      "metadata": {
        "id": "UIfqxeKKgTuN",
        "outputId": "f82c044b-0576-4785-ea07-c8c569f7c6c9",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 2,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "all_chat_datas.jsonl\t  dialogues\t    images  system_prompt.txt\t texts\n",
            "all_story_keywords.jsonl  gradio_header.md  jsonl   text_image_dict.txt\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "!pip -q install transformers openai tiktoken langchain chromadb"
      ],
      "metadata": {
        "id": "ZeBFaAOhhgH5",
        "outputId": "6cbb6cc7-8802-43d1-931b-508fe5dcfb1d",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 3,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m7.4/7.4 MB\u001b[0m \u001b[31m16.3 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m73.6/73.6 kB\u001b[0m \u001b[31m7.5 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m1.7/1.7 MB\u001b[0m \u001b[31m28.4 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m1.5/1.5 MB\u001b[0m \u001b[31m38.2 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m405.5/405.5 kB\u001b[0m \u001b[31m31.7 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m268.8/268.8 kB\u001b[0m \u001b[31m22.1 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m7.8/7.8 MB\u001b[0m \u001b[31m47.8 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m1.3/1.3 MB\u001b[0m \u001b[31m41.0 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m3.1/3.1 MB\u001b[0m \u001b[31m45.3 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[?25h  Installing build dependencies ... \u001b[?25l\u001b[?25hdone\n",
            "  Getting requirements to build wheel ... \u001b[?25l\u001b[?25hdone\n",
            "  Preparing metadata (pyproject.toml) ... \u001b[?25l\u001b[?25hdone\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m58.4/58.4 kB\u001b[0m \u001b[31m5.4 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m59.5/59.5 kB\u001b[0m \u001b[31m4.7 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m5.3/5.3 MB\u001b[0m \u001b[31m54.5 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m5.9/5.9 MB\u001b[0m \u001b[31m57.6 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m67.3/67.3 kB\u001b[0m \u001b[31m5.8 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[?25h  Installing build dependencies ... \u001b[?25l\u001b[?25hdone\n",
            "  Getting requirements to build wheel ... \u001b[?25l\u001b[?25hdone\n",
            "  Preparing metadata (pyproject.toml) ... \u001b[?25l\u001b[?25hdone\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m49.4/49.4 kB\u001b[0m \u001b[31m3.9 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m67.0/67.0 kB\u001b[0m \u001b[31m5.5 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m46.0/46.0 kB\u001b[0m \u001b[31m4.2 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m58.3/58.3 kB\u001b[0m \u001b[31m5.7 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m428.8/428.8 kB\u001b[0m \u001b[31m33.0 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m4.1/4.1 MB\u001b[0m \u001b[31m68.8 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m1.3/1.3 MB\u001b[0m \u001b[31m62.0 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m129.9/129.9 kB\u001b[0m \u001b[31m12.7 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[2K     \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m86.8/86.8 kB\u001b[0m \u001b[31m7.8 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
            "\u001b[?25h  Building wheel for chroma-hnswlib (pyproject.toml) ... \u001b[?25l\u001b[?25hdone\n",
            "  Building wheel for pypika (pyproject.toml) ... \u001b[?25l\u001b[?25hdone\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "import json\n",
        "\n",
        "def get_texts_and_embeds(role_name):\n",
        "    texts = []\n",
        "    vecs = []\n",
        "\n",
        "    file_name = f\"/content/Chat-Haruhi-Suzumiya/characters/{role_name}/jsonl/title_text_embed.jsonl\"\n",
        "\n",
        "\n",
        "\n",
        "    title_text_embed = {}\n",
        "\n",
        "    text_embed = {}\n",
        "    title_to_text = {}\n",
        "\n",
        "    texts = []\n",
        "    vecs = []\n",
        "\n",
        "    with open(file_name, 'r', encoding='utf-8') as f:\n",
        "        for line in f:\n",
        "            data = json.loads(line)\n",
        "            title_text_embed.update(data)\n",
        "\n",
        "    for title_text, embed in title_text_embed.items():\n",
        "        res = title_text.split(\"｜｜｜\")\n",
        "        title_to_text[res[0]] = res[1]\n",
        "        text_embed[res[1]] = embed\n",
        "\n",
        "        texts.append(res[1])\n",
        "        vecs.append(embed)\n",
        "\n",
        "    return texts, vecs\n"
      ],
      "metadata": {
        "id": "f-fTjtfYgcPZ"
      },
      "execution_count": 4,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "texts, vecs = get_texts_and_embeds(\"haruhi\")\n",
        "print(len(texts))"
      ],
      "metadata": {
        "id": "r7Zgqqq7gxEs",
        "outputId": "3a431492-4960-48e3-9890-50d4046c829a",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 5,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "172\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "%cd /content\n",
        "!rm -rf /content/Haruhi-2-Dev\n",
        "!git clone https://github.com/LC1332/Haruhi-2-Dev\n",
        "%cd /content/Haruhi-2-Dev\n"
      ],
      "metadata": {
        "id": "ffhhepV5gym8",
        "outputId": "00cc0afa-25a3-4bc2-e3e3-52a3dfb30b1d",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 6,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "/content\n",
            "Cloning into 'Haruhi-2-Dev'...\n",
            "remote: Enumerating objects: 435, done.\u001b[K\n",
            "remote: Counting objects: 100% (42/42), done.\u001b[K\n",
            "remote: Compressing objects: 100% (38/38), done.\u001b[K\n",
            "remote: Total 435 (delta 22), reused 11 (delta 4), pack-reused 393\u001b[K\n",
            "Receiving objects: 100% (435/435), 1.53 MiB | 10.27 MiB/s, done.\n",
            "Resolving deltas: 100% (160/160), done.\n",
            "/content/Haruhi-2-Dev\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "!ls /content/Chat-Haruhi-Suzumiya/characters/haruhi/*.txt"
      ],
      "metadata": {
        "id": "Mb_GV5XIi02e",
        "outputId": "add0eb58-e9d8-4777-a4b0-003279c08bc8",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 7,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "/content/Chat-Haruhi-Suzumiya/characters/haruhi/system_prompt.txt\n",
            "/content/Chat-Haruhi-Suzumiya/characters/haruhi/text_image_dict.txt\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "role_name = \"hutao\"\n",
        "\n",
        "!rm -r -f /content/{role_name}\n",
        "!rm /content/{role_name}.zip"
      ],
      "metadata": {
        "id": "2Sw8TS48kCSG",
        "outputId": "2375ef6d-3439-45b4-a265-06844674cb56",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 8,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "rm: cannot remove '/content/hutao.zip': No such file or directory\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "from ChatHaruhi import ChatHaruhi\n",
        "\n",
        "folder_names = ['tangshiye','murongfu','liyunlong',\n",
        "                'Luna','wangduoyu','Ron','jiumozhi',\n",
        "                'Snape','haruhi','Malfoy','xuzhu',\n",
        "                'xiaofeng','duanyu','Hermione','Dumbledore',\n",
        "                'wangyuyan',\n",
        "                'Harry','McGonagall' ,\n",
        "                'baizhantang','tongxiangyu','guofurong',\n",
        "                'wanderer','zhongli','hutao',\n",
        "                'Sheldon','Raj','Penny',\n",
        "                'weixiaobao','qiaofeng','ayaka',\n",
        "                'raidenShogun','yuqian']\n",
        "\n",
        "\n",
        "for role_name in folder_names:\n",
        "\n",
        "    file_prompt = f\"/content/Chat-Haruhi-Suzumiya/characters/{ role_name }/system_prompt.txt\"\n",
        "\n",
        "    save_path = f\"/content/{role_name }\"\n",
        "\n",
        "    chatbot = ChatHaruhi( system_prompt = file_prompt,\\\n",
        "                        llm = 'debug' ,\\\n",
        "                        story_db = None)\n",
        "\n",
        "    texts, vecs = get_texts_and_embeds( role_name )\n",
        "\n",
        "    print('len of story = ', len(texts))\n",
        "\n",
        "    chatbot.build_story_db_from_vec( texts, vecs)\n",
        "\n",
        "    import os\n",
        "\n",
        "    if os.path.exists( save_path ):\n",
        "        os.remove( save_path )\n",
        "\n",
        "    chatbot.save_story_db( save_path )\n",
        "\n",
        "\n",
        "\n",
        "    zip_file_name = f'/content/{role_name}.zip'\n",
        "\n",
        "    if os.path.exists( zip_file_name ):\n",
        "        os.remove( zip_file_name )\n",
        "\n",
        "\n",
        "    !cp /content/Chat-Haruhi-Suzumiya/characters/{role_name}/system_prompt.txt /content/\n",
        "\n",
        "    !zip -r /content/{role_name}.zip /content/{role_name} /content/system_prompt.txt\n",
        "\n",
        "# !rm -r -f /content/haruhi\n",
        "# !rm /content/haruhi.zip\n",
        "\n",
        "# !cp /content/Haruhi-2-Dev/data/characters/haruhi/system_prompt.txt /content/\n",
        "\n",
        "# !zip -r /content/haruhi.zip /content/haruhi /content/system_prompt.txt\n"
      ],
      "metadata": {
        "id": "7HrNEPZriFWM",
        "outputId": "45d1c1f2-ec38-4edb-ca4b-a91622f226fb",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 9,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  42\n",
            "  adding: content/tangshiye/ (stored 0%)\n",
            "  adding: content/tangshiye/35f0aadb-4776-498c-9080-687567317ac9/ (stored 0%)\n",
            "  adding: content/tangshiye/35f0aadb-4776-498c-9080-687567317ac9/data_level0.bin (deflated 100%)\n",
            "  adding: content/tangshiye/35f0aadb-4776-498c-9080-687567317ac9/header.bin (deflated 61%)\n",
            "  adding: content/tangshiye/35f0aadb-4776-498c-9080-687567317ac9/length.bin (deflated 75%)\n",
            "  adding: content/tangshiye/35f0aadb-4776-498c-9080-687567317ac9/link_lists.bin (stored 0%)\n",
            "  adding: content/tangshiye/chroma.sqlite3 (deflated 49%)\n",
            "  adding: content/system_prompt.txt (deflated 30%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  116\n",
            "  adding: content/murongfu/ (stored 0%)\n",
            "  adding: content/murongfu/02997bb6-6335-4254-bf5e-c7f801461c32/ (stored 0%)\n",
            "  adding: content/murongfu/02997bb6-6335-4254-bf5e-c7f801461c32/data_level0.bin (deflated 100%)\n",
            "  adding: content/murongfu/02997bb6-6335-4254-bf5e-c7f801461c32/header.bin (deflated 61%)\n",
            "  adding: content/murongfu/02997bb6-6335-4254-bf5e-c7f801461c32/length.bin (deflated 35%)\n",
            "  adding: content/murongfu/02997bb6-6335-4254-bf5e-c7f801461c32/link_lists.bin (stored 0%)\n",
            "  adding: content/murongfu/chroma.sqlite3 (deflated 39%)\n",
            "  adding: content/system_prompt.txt (deflated 26%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  420\n",
            "  adding: content/liyunlong/ (stored 0%)\n",
            "  adding: content/liyunlong/9516c681-9f2d-4266-99e8-566acdc63efa/ (stored 0%)\n",
            "  adding: content/liyunlong/9516c681-9f2d-4266-99e8-566acdc63efa/data_level0.bin (deflated 100%)\n",
            "  adding: content/liyunlong/9516c681-9f2d-4266-99e8-566acdc63efa/header.bin (deflated 61%)\n",
            "  adding: content/liyunlong/9516c681-9f2d-4266-99e8-566acdc63efa/length.bin (deflated 47%)\n",
            "  adding: content/liyunlong/9516c681-9f2d-4266-99e8-566acdc63efa/link_lists.bin (stored 0%)\n",
            "  adding: content/liyunlong/chroma.sqlite3 (deflated 38%)\n",
            "  adding: content/system_prompt.txt (deflated 40%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  46\n",
            "  adding: content/Luna/ (stored 0%)\n",
            "  adding: content/Luna/chroma.sqlite3 (deflated 50%)\n",
            "  adding: content/Luna/2adc7970-4784-4360-bf19-40ae47241c27/ (stored 0%)\n",
            "  adding: content/Luna/2adc7970-4784-4360-bf19-40ae47241c27/data_level0.bin (deflated 100%)\n",
            "  adding: content/Luna/2adc7970-4784-4360-bf19-40ae47241c27/header.bin (deflated 61%)\n",
            "  adding: content/Luna/2adc7970-4784-4360-bf19-40ae47241c27/length.bin (deflated 89%)\n",
            "  adding: content/Luna/2adc7970-4784-4360-bf19-40ae47241c27/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 25%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  46\n",
            "  adding: content/wangduoyu/ (stored 0%)\n",
            "  adding: content/wangduoyu/8663f3fe-1b52-4e51-9e2f-1a2322357ff3/ (stored 0%)\n",
            "  adding: content/wangduoyu/8663f3fe-1b52-4e51-9e2f-1a2322357ff3/data_level0.bin (deflated 100%)\n",
            "  adding: content/wangduoyu/8663f3fe-1b52-4e51-9e2f-1a2322357ff3/header.bin (deflated 61%)\n",
            "  adding: content/wangduoyu/8663f3fe-1b52-4e51-9e2f-1a2322357ff3/length.bin (deflated 34%)\n",
            "  adding: content/wangduoyu/8663f3fe-1b52-4e51-9e2f-1a2322357ff3/link_lists.bin (stored 0%)\n",
            "  adding: content/wangduoyu/chroma.sqlite3 (deflated 48%)\n",
            "  adding: content/system_prompt.txt (deflated 35%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  788\n",
            "  adding: content/Ron/ (stored 0%)\n",
            "  adding: content/Ron/chroma.sqlite3 (deflated 45%)\n",
            "  adding: content/Ron/6c92f867-c278-4b3f-90e2-35e13e237fd7/ (stored 0%)\n",
            "  adding: content/Ron/6c92f867-c278-4b3f-90e2-35e13e237fd7/data_level0.bin (deflated 100%)\n",
            "  adding: content/Ron/6c92f867-c278-4b3f-90e2-35e13e237fd7/header.bin (deflated 61%)\n",
            "  adding: content/Ron/6c92f867-c278-4b3f-90e2-35e13e237fd7/length.bin (deflated 98%)\n",
            "  adding: content/Ron/6c92f867-c278-4b3f-90e2-35e13e237fd7/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 21%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  57\n",
            "  adding: content/jiumozhi/ (stored 0%)\n",
            "  adding: content/jiumozhi/53fc4173-459d-4757-b28d-331f5d099c4e/ (stored 0%)\n",
            "  adding: content/jiumozhi/53fc4173-459d-4757-b28d-331f5d099c4e/data_level0.bin (deflated 75%)\n",
            "  adding: content/jiumozhi/53fc4173-459d-4757-b28d-331f5d099c4e/header.bin (deflated 61%)\n",
            "  adding: content/jiumozhi/53fc4173-459d-4757-b28d-331f5d099c4e/length.bin (deflated 76%)\n",
            "  adding: content/jiumozhi/53fc4173-459d-4757-b28d-331f5d099c4e/link_lists.bin (stored 0%)\n",
            "  adding: content/jiumozhi/chroma.sqlite3 (deflated 44%)\n",
            "  adding: content/system_prompt.txt (deflated 25%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  101\n",
            "  adding: content/Snape/ (stored 0%)\n",
            "  adding: content/Snape/393469ab-345e-41a8-bd0d-0abeeaeba490/ (stored 0%)\n",
            "  adding: content/Snape/393469ab-345e-41a8-bd0d-0abeeaeba490/data_level0.bin (deflated 100%)\n",
            "  adding: content/Snape/393469ab-345e-41a8-bd0d-0abeeaeba490/header.bin (deflated 61%)\n",
            "  adding: content/Snape/393469ab-345e-41a8-bd0d-0abeeaeba490/length.bin (deflated 65%)\n",
            "  adding: content/Snape/393469ab-345e-41a8-bd0d-0abeeaeba490/link_lists.bin (stored 0%)\n",
            "  adding: content/Snape/chroma.sqlite3 (deflated 52%)\n",
            "  adding: content/system_prompt.txt (deflated 28%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  172\n",
            "  adding: content/haruhi/ (stored 0%)\n",
            "  adding: content/haruhi/aba97f7a-5615-48b0-ab46-571d42d591a8/ (stored 0%)\n",
            "  adding: content/haruhi/aba97f7a-5615-48b0-ab46-571d42d591a8/data_level0.bin (deflated 100%)\n",
            "  adding: content/haruhi/aba97f7a-5615-48b0-ab46-571d42d591a8/header.bin (deflated 61%)\n",
            "  adding: content/haruhi/aba97f7a-5615-48b0-ab46-571d42d591a8/length.bin (deflated 68%)\n",
            "  adding: content/haruhi/aba97f7a-5615-48b0-ab46-571d42d591a8/link_lists.bin (stored 0%)\n",
            "  adding: content/haruhi/chroma.sqlite3 (deflated 41%)\n",
            "  adding: content/system_prompt.txt (deflated 36%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  99\n",
            "  adding: content/Malfoy/ (stored 0%)\n",
            "  adding: content/Malfoy/d3d7102d-625a-4cdb-b9e3-ab6a11368177/ (stored 0%)\n",
            "  adding: content/Malfoy/d3d7102d-625a-4cdb-b9e3-ab6a11368177/data_level0.bin (deflated 98%)\n",
            "  adding: content/Malfoy/d3d7102d-625a-4cdb-b9e3-ab6a11368177/header.bin (deflated 61%)\n",
            "  adding: content/Malfoy/d3d7102d-625a-4cdb-b9e3-ab6a11368177/length.bin (deflated 36%)\n",
            "  adding: content/Malfoy/d3d7102d-625a-4cdb-b9e3-ab6a11368177/link_lists.bin (stored 0%)\n",
            "  adding: content/Malfoy/chroma.sqlite3 (deflated 46%)\n",
            "  adding: content/system_prompt.txt (deflated 25%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  132\n",
            "  adding: content/xuzhu/ (stored 0%)\n",
            "  adding: content/xuzhu/ac85fc10-0aed-4667-aad3-2c32f5f7c2a0/ (stored 0%)\n",
            "  adding: content/xuzhu/ac85fc10-0aed-4667-aad3-2c32f5f7c2a0/data_level0.bin (deflated 100%)\n",
            "  adding: content/xuzhu/ac85fc10-0aed-4667-aad3-2c32f5f7c2a0/header.bin (deflated 61%)\n",
            "  adding: content/xuzhu/ac85fc10-0aed-4667-aad3-2c32f5f7c2a0/length.bin (deflated 68%)\n",
            "  adding: content/xuzhu/ac85fc10-0aed-4667-aad3-2c32f5f7c2a0/link_lists.bin (stored 0%)\n",
            "  adding: content/xuzhu/chroma.sqlite3 (deflated 40%)\n",
            "  adding: content/system_prompt.txt (deflated 26%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  159\n",
            "  adding: content/xiaofeng/ (stored 0%)\n",
            "  adding: content/xiaofeng/5f2a531e-d31e-4962-aaa4-3c3aa8ec52df/ (stored 0%)\n",
            "  adding: content/xiaofeng/5f2a531e-d31e-4962-aaa4-3c3aa8ec52df/data_level0.bin (deflated 100%)\n",
            "  adding: content/xiaofeng/5f2a531e-d31e-4962-aaa4-3c3aa8ec52df/header.bin (deflated 61%)\n",
            "  adding: content/xiaofeng/5f2a531e-d31e-4962-aaa4-3c3aa8ec52df/length.bin (deflated 68%)\n",
            "  adding: content/xiaofeng/5f2a531e-d31e-4962-aaa4-3c3aa8ec52df/link_lists.bin (stored 0%)\n",
            "  adding: content/xiaofeng/chroma.sqlite3 (deflated 37%)\n",
            "  adding: content/system_prompt.txt (deflated 24%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  328\n",
            "  adding: content/duanyu/ (stored 0%)\n",
            "  adding: content/duanyu/d0f78e3f-3711-4000-b12d-366862ba95bd/ (stored 0%)\n",
            "  adding: content/duanyu/d0f78e3f-3711-4000-b12d-366862ba95bd/data_level0.bin (deflated 91%)\n",
            "  adding: content/duanyu/d0f78e3f-3711-4000-b12d-366862ba95bd/header.bin (deflated 61%)\n",
            "  adding: content/duanyu/d0f78e3f-3711-4000-b12d-366862ba95bd/length.bin (deflated 27%)\n",
            "  adding: content/duanyu/d0f78e3f-3711-4000-b12d-366862ba95bd/link_lists.bin (stored 0%)\n",
            "  adding: content/duanyu/chroma.sqlite3 (deflated 35%)\n",
            "  adding: content/system_prompt.txt (deflated 25%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  781\n",
            "  adding: content/Hermione/ (stored 0%)\n",
            "  adding: content/Hermione/b0f513e5-0094-452c-a426-770150ecb313/ (stored 0%)\n",
            "  adding: content/Hermione/b0f513e5-0094-452c-a426-770150ecb313/data_level0.bin (deflated 100%)\n",
            "  adding: content/Hermione/b0f513e5-0094-452c-a426-770150ecb313/header.bin (deflated 61%)\n",
            "  adding: content/Hermione/b0f513e5-0094-452c-a426-770150ecb313/length.bin (deflated 83%)\n",
            "  adding: content/Hermione/b0f513e5-0094-452c-a426-770150ecb313/link_lists.bin (stored 0%)\n",
            "  adding: content/Hermione/chroma.sqlite3 (deflated 45%)\n",
            "  adding: content/system_prompt.txt (deflated 27%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  210\n",
            "  adding: content/Dumbledore/ (stored 0%)\n",
            "  adding: content/Dumbledore/6676c0f3-9e0f-40db-aab2-76a4ab1ae8ac/ (stored 0%)\n",
            "  adding: content/Dumbledore/6676c0f3-9e0f-40db-aab2-76a4ab1ae8ac/data_level0.bin (deflated 100%)\n",
            "  adding: content/Dumbledore/6676c0f3-9e0f-40db-aab2-76a4ab1ae8ac/header.bin (deflated 61%)\n",
            "  adding: content/Dumbledore/6676c0f3-9e0f-40db-aab2-76a4ab1ae8ac/length.bin (deflated 60%)\n",
            "  adding: content/Dumbledore/6676c0f3-9e0f-40db-aab2-76a4ab1ae8ac/link_lists.bin (stored 0%)\n",
            "  adding: content/Dumbledore/chroma.sqlite3 (deflated 48%)\n",
            "  adding: content/system_prompt.txt (deflated 30%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  141\n",
            "  adding: content/wangyuyan/ (stored 0%)\n",
            "  adding: content/wangyuyan/chroma.sqlite3 (deflated 39%)\n",
            "  adding: content/wangyuyan/c719bbdb-d906-44aa-b7d9-7df0c599c047/ (stored 0%)\n",
            "  adding: content/wangyuyan/c719bbdb-d906-44aa-b7d9-7df0c599c047/data_level0.bin (deflated 100%)\n",
            "  adding: content/wangyuyan/c719bbdb-d906-44aa-b7d9-7df0c599c047/header.bin (deflated 61%)\n",
            "  adding: content/wangyuyan/c719bbdb-d906-44aa-b7d9-7df0c599c047/length.bin (deflated 88%)\n",
            "  adding: content/wangyuyan/c719bbdb-d906-44aa-b7d9-7df0c599c047/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 27%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  1407\n",
            "  adding: content/Harry/ (stored 0%)\n",
            "  adding: content/Harry/16d2daf5-9b1b-40e1-b8f0-e6591b35287e/ (stored 0%)\n",
            "  adding: content/Harry/16d2daf5-9b1b-40e1-b8f0-e6591b35287e/data_level0.bin (deflated 17%)\n",
            "  adding: content/Harry/16d2daf5-9b1b-40e1-b8f0-e6591b35287e/header.bin (deflated 56%)\n",
            "  adding: content/Harry/16d2daf5-9b1b-40e1-b8f0-e6591b35287e/length.bin (deflated 53%)\n",
            "  adding: content/Harry/16d2daf5-9b1b-40e1-b8f0-e6591b35287e/index_metadata.pickle (deflated 63%)\n",
            "  adding: content/Harry/16d2daf5-9b1b-40e1-b8f0-e6591b35287e/link_lists.bin (deflated 87%)\n",
            "  adding: content/Harry/chroma.sqlite3 (deflated 47%)\n",
            "  adding: content/system_prompt.txt (deflated 25%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  92\n",
            "  adding: content/McGonagall/ (stored 0%)\n",
            "  adding: content/McGonagall/119be56b-fd96-492e-8bdb-574a663228c2/ (stored 0%)\n",
            "  adding: content/McGonagall/119be56b-fd96-492e-8bdb-574a663228c2/data_level0.bin (deflated 100%)\n",
            "  adding: content/McGonagall/119be56b-fd96-492e-8bdb-574a663228c2/header.bin (deflated 61%)\n",
            "  adding: content/McGonagall/119be56b-fd96-492e-8bdb-574a663228c2/length.bin (deflated 95%)\n",
            "  adding: content/McGonagall/119be56b-fd96-492e-8bdb-574a663228c2/link_lists.bin (stored 0%)\n",
            "  adding: content/McGonagall/chroma.sqlite3 (deflated 48%)\n",
            "  adding: content/system_prompt.txt (deflated 29%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  295\n",
            "  adding: content/baizhantang/ (stored 0%)\n",
            "  adding: content/baizhantang/25a04bcf-1ae1-4cc5-9bea-e67370a1fcdc/ (stored 0%)\n",
            "  adding: content/baizhantang/25a04bcf-1ae1-4cc5-9bea-e67370a1fcdc/data_level0.bin (deflated 100%)\n",
            "  adding: content/baizhantang/25a04bcf-1ae1-4cc5-9bea-e67370a1fcdc/header.bin (deflated 61%)\n",
            "  adding: content/baizhantang/25a04bcf-1ae1-4cc5-9bea-e67370a1fcdc/length.bin (deflated 66%)\n",
            "  adding: content/baizhantang/25a04bcf-1ae1-4cc5-9bea-e67370a1fcdc/link_lists.bin (stored 0%)\n",
            "  adding: content/baizhantang/chroma.sqlite3 (deflated 40%)\n",
            "  adding: content/system_prompt.txt (deflated 27%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  276\n",
            "  adding: content/tongxiangyu/ (stored 0%)\n",
            "  adding: content/tongxiangyu/e50bf54b-2e04-4cfa-b371-93e981e36f26/ (stored 0%)\n",
            "  adding: content/tongxiangyu/e50bf54b-2e04-4cfa-b371-93e981e36f26/data_level0.bin (deflated 100%)\n",
            "  adding: content/tongxiangyu/e50bf54b-2e04-4cfa-b371-93e981e36f26/header.bin (deflated 61%)\n",
            "  adding: content/tongxiangyu/e50bf54b-2e04-4cfa-b371-93e981e36f26/length.bin (deflated 96%)\n",
            "  adding: content/tongxiangyu/e50bf54b-2e04-4cfa-b371-93e981e36f26/link_lists.bin (stored 0%)\n",
            "  adding: content/tongxiangyu/chroma.sqlite3 (deflated 42%)\n",
            "  adding: content/system_prompt.txt (deflated 27%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  224\n",
            "  adding: content/guofurong/ (stored 0%)\n",
            "  adding: content/guofurong/c5bbd84d-00b2-4fdd-93af-ff4a247a9474/ (stored 0%)\n",
            "  adding: content/guofurong/c5bbd84d-00b2-4fdd-93af-ff4a247a9474/data_level0.bin (deflated 82%)\n",
            "  adding: content/guofurong/c5bbd84d-00b2-4fdd-93af-ff4a247a9474/header.bin (deflated 61%)\n",
            "  adding: content/guofurong/c5bbd84d-00b2-4fdd-93af-ff4a247a9474/length.bin (deflated 55%)\n",
            "  adding: content/guofurong/c5bbd84d-00b2-4fdd-93af-ff4a247a9474/link_lists.bin (stored 0%)\n",
            "  adding: content/guofurong/chroma.sqlite3 (deflated 40%)\n",
            "  adding: content/system_prompt.txt (deflated 28%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  180\n",
            "  adding: content/wanderer/ (stored 0%)\n",
            "  adding: content/wanderer/c9f4fbb2-59a9-48b7-9804-6fa460c8c70f/ (stored 0%)\n",
            "  adding: content/wanderer/c9f4fbb2-59a9-48b7-9804-6fa460c8c70f/data_level0.bin (deflated 100%)\n",
            "  adding: content/wanderer/c9f4fbb2-59a9-48b7-9804-6fa460c8c70f/header.bin (deflated 61%)\n",
            "  adding: content/wanderer/c9f4fbb2-59a9-48b7-9804-6fa460c8c70f/length.bin (deflated 54%)\n",
            "  adding: content/wanderer/c9f4fbb2-59a9-48b7-9804-6fa460c8c70f/link_lists.bin (stored 0%)\n",
            "  adding: content/wanderer/chroma.sqlite3 (deflated 38%)\n",
            "  adding: content/system_prompt.txt (deflated 35%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  270\n",
            "  adding: content/zhongli/ (stored 0%)\n",
            "  adding: content/zhongli/74ac2b69-efaa-446f-86a6-12380be88af4/ (stored 0%)\n",
            "  adding: content/zhongli/74ac2b69-efaa-446f-86a6-12380be88af4/data_level0.bin (deflated 91%)\n",
            "  adding: content/zhongli/74ac2b69-efaa-446f-86a6-12380be88af4/header.bin (deflated 61%)\n",
            "  adding: content/zhongli/74ac2b69-efaa-446f-86a6-12380be88af4/length.bin (deflated 71%)\n",
            "  adding: content/zhongli/74ac2b69-efaa-446f-86a6-12380be88af4/link_lists.bin (stored 0%)\n",
            "  adding: content/zhongli/chroma.sqlite3 (deflated 41%)\n",
            "  adding: content/system_prompt.txt (deflated 39%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  141\n",
            "  adding: content/hutao/ (stored 0%)\n",
            "  adding: content/hutao/chroma.sqlite3 (deflated 39%)\n",
            "  adding: content/hutao/33c361e5-c773-42ca-bb1e-d90b93bab8ad/ (stored 0%)\n",
            "  adding: content/hutao/33c361e5-c773-42ca-bb1e-d90b93bab8ad/data_level0.bin (deflated 100%)\n",
            "  adding: content/hutao/33c361e5-c773-42ca-bb1e-d90b93bab8ad/header.bin (deflated 61%)\n",
            "  adding: content/hutao/33c361e5-c773-42ca-bb1e-d90b93bab8ad/length.bin (deflated 99%)\n",
            "  adding: content/hutao/33c361e5-c773-42ca-bb1e-d90b93bab8ad/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 34%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  285\n",
            "  adding: content/Sheldon/ (stored 0%)\n",
            "  adding: content/Sheldon/chroma.sqlite3 (deflated 50%)\n",
            "  adding: content/Sheldon/006a61db-12d6-4631-8c4f-df7ca4e5da8d/ (stored 0%)\n",
            "  adding: content/Sheldon/006a61db-12d6-4631-8c4f-df7ca4e5da8d/data_level0.bin (deflated 100%)\n",
            "  adding: content/Sheldon/006a61db-12d6-4631-8c4f-df7ca4e5da8d/header.bin (deflated 61%)\n",
            "  adding: content/Sheldon/006a61db-12d6-4631-8c4f-df7ca4e5da8d/length.bin (deflated 52%)\n",
            "  adding: content/Sheldon/006a61db-12d6-4631-8c4f-df7ca4e5da8d/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 25%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  129\n",
            "  adding: content/Raj/ (stored 0%)\n",
            "  adding: content/Raj/chroma.sqlite3 (deflated 49%)\n",
            "  adding: content/Raj/2b4d966e-af96-43cf-bc2a-01508bfaf6fa/ (stored 0%)\n",
            "  adding: content/Raj/2b4d966e-af96-43cf-bc2a-01508bfaf6fa/data_level0.bin (deflated 83%)\n",
            "  adding: content/Raj/2b4d966e-af96-43cf-bc2a-01508bfaf6fa/header.bin (deflated 61%)\n",
            "  adding: content/Raj/2b4d966e-af96-43cf-bc2a-01508bfaf6fa/length.bin (deflated 99%)\n",
            "  adding: content/Raj/2b4d966e-af96-43cf-bc2a-01508bfaf6fa/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 28%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  152\n",
            "  adding: content/Penny/ (stored 0%)\n",
            "  adding: content/Penny/chroma.sqlite3 (deflated 54%)\n",
            "  adding: content/Penny/079257ea-6b23-400a-982d-ea719922d26d/ (stored 0%)\n",
            "  adding: content/Penny/079257ea-6b23-400a-982d-ea719922d26d/data_level0.bin (deflated 91%)\n",
            "  adding: content/Penny/079257ea-6b23-400a-982d-ea719922d26d/header.bin (deflated 61%)\n",
            "  adding: content/Penny/079257ea-6b23-400a-982d-ea719922d26d/length.bin (deflated 50%)\n",
            "  adding: content/Penny/079257ea-6b23-400a-982d-ea719922d26d/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 27%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  1048\n",
            "  adding: content/weixiaobao/ (stored 0%)\n",
            "  adding: content/weixiaobao/88ab822f-b672-4465-ab1b-3ac5a436d7f8/ (stored 0%)\n",
            "  adding: content/weixiaobao/88ab822f-b672-4465-ab1b-3ac5a436d7f8/data_level0.bin (deflated 9%)\n",
            "  adding: content/weixiaobao/88ab822f-b672-4465-ab1b-3ac5a436d7f8/header.bin (deflated 56%)\n",
            "  adding: content/weixiaobao/88ab822f-b672-4465-ab1b-3ac5a436d7f8/length.bin (deflated 38%)\n",
            "  adding: content/weixiaobao/88ab822f-b672-4465-ab1b-3ac5a436d7f8/index_metadata.pickle (deflated 58%)\n",
            "  adding: content/weixiaobao/88ab822f-b672-4465-ab1b-3ac5a436d7f8/link_lists.bin (deflated 87%)\n",
            "  adding: content/weixiaobao/chroma.sqlite3 (deflated 38%)\n",
            "  adding: content/system_prompt.txt (deflated 24%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  129\n",
            "  adding: content/qiaofeng/ (stored 0%)\n",
            "  adding: content/qiaofeng/1bae82ef-86ce-4d06-b066-3931e9c88ed6/ (stored 0%)\n",
            "  adding: content/qiaofeng/1bae82ef-86ce-4d06-b066-3931e9c88ed6/data_level0.bin (deflated 89%)\n",
            "  adding: content/qiaofeng/1bae82ef-86ce-4d06-b066-3931e9c88ed6/header.bin (deflated 61%)\n",
            "  adding: content/qiaofeng/1bae82ef-86ce-4d06-b066-3931e9c88ed6/length.bin (deflated 35%)\n",
            "  adding: content/qiaofeng/1bae82ef-86ce-4d06-b066-3931e9c88ed6/link_lists.bin (stored 0%)\n",
            "  adding: content/qiaofeng/chroma.sqlite3 (deflated 41%)\n",
            "  adding: content/system_prompt.txt (deflated 27%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  117\n",
            "  adding: content/ayaka/ (stored 0%)\n",
            "  adding: content/ayaka/chroma.sqlite3 (deflated 47%)\n",
            "  adding: content/ayaka/8d5d4190-ef57-4ff7-9874-07b5e324a10d/ (stored 0%)\n",
            "  adding: content/ayaka/8d5d4190-ef57-4ff7-9874-07b5e324a10d/data_level0.bin (deflated 81%)\n",
            "  adding: content/ayaka/8d5d4190-ef57-4ff7-9874-07b5e324a10d/header.bin (deflated 61%)\n",
            "  adding: content/ayaka/8d5d4190-ef57-4ff7-9874-07b5e324a10d/length.bin (deflated 36%)\n",
            "  adding: content/ayaka/8d5d4190-ef57-4ff7-9874-07b5e324a10d/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 33%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  215\n",
            "  adding: content/raidenShogun/ (stored 0%)\n",
            "  adding: content/raidenShogun/chroma.sqlite3 (deflated 37%)\n",
            "  adding: content/raidenShogun/88741cc5-66e7-4710-b9fb-f1e6820dc291/ (stored 0%)\n",
            "  adding: content/raidenShogun/88741cc5-66e7-4710-b9fb-f1e6820dc291/data_level0.bin (deflated 62%)\n",
            "  adding: content/raidenShogun/88741cc5-66e7-4710-b9fb-f1e6820dc291/header.bin (deflated 61%)\n",
            "  adding: content/raidenShogun/88741cc5-66e7-4710-b9fb-f1e6820dc291/length.bin (deflated 31%)\n",
            "  adding: content/raidenShogun/88741cc5-66e7-4710-b9fb-f1e6820dc291/link_lists.bin (stored 0%)\n",
            "  adding: content/system_prompt.txt (deflated 37%)\n",
            "warning! database not yet figured out, both story_db and story_text_folder are not inputted.\n",
            "len of story =  1726\n",
            "  adding: content/yuqian/ (stored 0%)\n",
            "  adding: content/yuqian/cbb3b22a-f96e-4b79-b9b3-7bb252c6a818/ (stored 0%)\n",
            "  adding: content/yuqian/cbb3b22a-f96e-4b79-b9b3-7bb252c6a818/data_level0.bin (deflated 9%)\n",
            "  adding: content/yuqian/cbb3b22a-f96e-4b79-b9b3-7bb252c6a818/header.bin (deflated 56%)\n",
            "  adding: content/yuqian/cbb3b22a-f96e-4b79-b9b3-7bb252c6a818/length.bin (deflated 66%)\n",
            "  adding: content/yuqian/cbb3b22a-f96e-4b79-b9b3-7bb252c6a818/index_metadata.pickle (deflated 63%)\n",
            "  adding: content/yuqian/cbb3b22a-f96e-4b79-b9b3-7bb252c6a818/link_lists.bin (deflated 87%)\n",
            "  adding: content/yuqian/chroma.sqlite3 (deflated 34%)\n",
            "  adding: content/system_prompt.txt (deflated 43%)\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "!ll /content/haruhi.zip"
      ],
      "metadata": {
        "id": "rxF2YdutklUK",
        "outputId": "f8712309-0fef-4b08-fa85-7a08c5d492f9",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 10,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "/bin/bash: line 1: ll: command not found\n"
          ]
        }
      ]
    },
    {
      "cell_type": "markdown",
      "source": [
        "我希望把/content目录下的所有zip 打包到output.zip\n",
        "\n",
        "请用shell为我实现"
      ],
      "metadata": {
        "id": "QoscZc4vomTp"
      }
    },
    {
      "cell_type": "code",
      "source": [
        "from google.colab import drive\n",
        "drive.mount('/content/drive')"
      ],
      "metadata": {
        "id": "TtAR7wuoo35r",
        "outputId": "8ad0b442-f977-4f4a-897b-091950a85540",
        "colab": {
          "base_uri": "https://localhost:8080/"
        }
      },
      "execution_count": 12,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Mounted at /content/drive\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "!rm -rf /content/drive/MyDrive/GPTData/AllZip"
      ],
      "metadata": {
        "id": "ScuoTutmqlmc"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "!mkdir -p /content/drive/MyDrive/GPTData/AllZip2\n",
        "\n",
        "!find /content -maxdepth 1 -name \"*.zip\" -exec mv {} /content/drive/MyDrive/GPTData/AllZip2 \\;"
      ],
      "metadata": {
        "id": "6V0JU7XPqFgX"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "markdown",
      "source": [
        "如何用shell指令将/content下的所有zip转移到/content/drive/MyDrive/GPTData/AllZip"
      ],
      "metadata": {
        "id": "4aUcn6cHqNXy"
      }
    },
    {
      "cell_type": "code",
      "source": [
        "!cp /content/*.zip /content/drive/MyDrive/GPTData/AllZip2"
      ],
      "metadata": {
        "id": "PEvAu7SCpG2T"
      },
      "execution_count": 13,
      "outputs": []
    },
    {
      "cell_type": "markdown",
      "source": [
        "!"
      ],
      "metadata": {
        "id": "S8g4aVerq8bq"
      }
    }
  ]
}